package lab02.test09;

public class Student {
     private String num;
     private int classNo;
     private String name;
     private String sex;
     private int age;

     public Student(){}

     public Student(String num,int classNo,String name,String sex,int age){

         this.age=age;
         this.classNo=classNo;
         this.name=name;
         this.num=num;
         this.sex=sex;
     }

    public String getNum() {
        return num;
    }

    public void setNum(String num) {
        this.num = num;
    }

    public int getClassNo() {
        return classNo;
    }

    public void setClassNo(int classNo) {
        this.classNo = classNo;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    @Override
    public String toString() {
        return  "学号："+num+"\n"+"班号："+classNo+"\n"+"姓名："+ name+"\n"+"性别："+sex+"\n"+"年龄："+ age;
    }
}
